﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Runtime.Serialization;
using System.Text;
using System.Threading.Tasks;

namespace Douban.API
{
    [DataContract]
    public class APIResponse
    {
        private string body;
        /// <summary>
        /// 响应原始内容
        /// </summary>
        public string Body
        {
            get
            {
                return body;
            }
            set
            {
                //非调试状态下没必要存储
                if (System.Diagnostics.Debugger.IsAttached)
                    this.body = value;
            }
        }

        public string ErrorCode { get; set; }

        public string Title { get; set; }

        public bool IsOK
        {
            get;
            internal set;
        }
    }
}
